'use strict';

/**
 * @param {Egg.Application} app - egg application
 * cinemaCtrl => cinemaController
 */
module.exports = app => {
    const {
        router,
        controller
    } = app;
    router.get('/', controller.homeController.index);
    router.get('/city', controller.homeController.city);
    // 影院模块
    app.router.get('/cinema', app.controller.cinemaController.list);
    app.router.get('/cinema/:id', app.controller.cinemaController.detail);
    // 影片模块
    app.router.get('/film/now-playing', app.controller.filmController.playing);
    app.router.get('/film/coming-soon', app.controller.filmController.coming);
    app.router.get('/film/:id', app.controller.filmController.detail);
};
